//
//  main.m
//  FirstClass
//
//  Created by hh on 16/4/5.
//  Copyright © 2016年 hh. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "Atom.h"
#import "Person.h"
#import "Mouse.h"

int main(int argc, const char * argv[]) {
    @autoreleasepool {
        // insert code here...
        NSLog(@"Hello, World!");
        Person *p = [[Person alloc] init];
        p.name = @"陈泽";
        
        Mouse *m = [[Mouse alloc] init];
        m.name = @"米老鼠";
        
        NSArray *arr = @[p, m];
        for (int i = 0; i < arr.count; i++) {
            Animal *ani = arr[i];
            [ani eat];
            [ani sleep];
        }
    }
    return 0;
}
